import axios from '@/utils/axios'

// 获取评论列表
export const comments = (page, perpage) => {
  return axios({
    method: 'GET',
    url: '/mp/v1_0/articles',
    params: {
      page,
      per_page: perpage,
      response_type: 'comment'
    }
  })
}

// 修改文章评论状态
export const commentStatus = (commentId, data) => {
  return axios({
    method: 'PUT',
    url: '/mp/v1_0/comments/status',
    params: {
      article_id: commentId
    },
    data
  })
}
